package mil.af.amc.adpetracker.model;

/**
 * Enumeration to specify the Condition of an EquipmentItem
 *
 * @author TSgt Jason Ferguson
 */

public enum Condition {
    A(0, "Serviceable"),
    H(1, "Unservicable");

    private String description;
    private int enumValue;

    Condition (int enumValue, String description) {
    //Condition(String description, String enumValue) {
        this.description = description;
        this.enumValue = enumValue;
    }

    public String getDescription() {
        return this.description;
    }

    public int getEnumValue() {
        return enumValue;
    }

    // Convenience method since JSP can't directly reference Enum's ordinal() method
    public int getOrdinalValue() {
        return this.ordinal();
    }
}
